package com.fhz.day006;

import androidx.appcompat.app.AppCompatActivity;

import android.os.Bundle;
import android.util.Log;
import android.view.MotionEvent;


public class MainActivity extends AppCompatActivity {

    private static final String TAG = "fengActivity";
    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
//        Density.setDensity(getApplication(),this);
        setContentView(R.layout.activity_main);


    }

    @Override
    public boolean dispatchTouchEvent(MotionEvent ev) {
        Log.i(TAG, "dispatchTouchEvent: activity的按下 ");
//        switch (ev.getAction()){
//            case MotionEvent.ACTION_DOWN:
//                Log.i(TAG, "dispatchTouchEvent: activity的按下 ");
//                break;
//            case MotionEvent.ACTION_UP:
//                Log.i(TAG, "dispatchTouchEvent: activity的弹出 ");
//                break;
//            case MotionEvent.ACTION_MOVE:
//                Log.i(TAG, "dispatchTouchEvent: activity的移动 ");
//                break;
//        }

        return super.dispatchTouchEvent(ev);

    }

    @Override
    public boolean onTouchEvent(MotionEvent event) {
        Log.i(TAG, "onTouchEvent: ");
        return super.onTouchEvent(event);
    }
}